An electrocardiogram (ECG) system monitors electrical activity of a heart of a patient. A normal electrocardiogram includes a P wave, a QRS complex, and a T wave. During arrhythmogenic activity, such as fibrillation, tachycardia or bradycardia, the shapes of the different constituent parts of the waveform may distort from the normal sinus shapes. Such changes in waveform morphology can further complicate detection and analysis based on such waveforms.